package it.unibo.iss.domotica.parser.antlr.internal; 

import org.eclipse.xtext.*;
import org.eclipse.xtext.parser.*;
import org.eclipse.xtext.parser.impl.*;
import org.eclipse.emf.ecore.util.EcoreUtil;
import org.eclipse.emf.ecore.EObject;
import org.eclipse.emf.common.util.Enumerator;
import org.eclipse.xtext.parser.antlr.AbstractInternalAntlrParser;
import org.eclipse.xtext.parser.antlr.XtextTokenStream;
import org.eclipse.xtext.parser.antlr.XtextTokenStream.HiddenTokens;
import org.eclipse.xtext.parser.antlr.AntlrDatatypeRuleToken;
import it.unibo.iss.domotica.services.DomoticDslGrammarAccess;



import org.antlr.runtime.*;
import java.util.Stack;
import java.util.List;
import java.util.ArrayList;

@SuppressWarnings("all")
public class InternalDomoticDslParser extends AbstractInternalAntlrParser {
    public static final String[] tokenNames = new String[] {
        "<invalid>", "<EOR>", "<DOWN>", "<UP>", "RULE_ID", "RULE_STRING", "RULE_DOUBLE", "RULE_INT", "RULE_ML_COMMENT", "RULE_SL_COMMENT", "RULE_WS", "RULE_ANY_OTHER", "'DomoticSystem'", "';'", "'package'", "'propertiesPath='", "'Elettrodomestico'", "'consumption='", "'usage='", "'Sensor'", "'for'", "'minConsumption='", "'maxConsumption='", "'LOW'", "'MEDIUM'", "'HIGH'", "'ESSENTIAL'", "'OPTIONAL'"
    };
    public static final int RULE_ID=4;
    public static final int T__27=27;
    public static final int T__26=26;
    public static final int T__25=25;
    public static final int T__24=24;
    public static final int T__23=23;
    public static final int T__22=22;
    public static final int RULE_ANY_OTHER=11;
    public static final int T__21=21;
    public static final int T__20=20;
    public static final int RULE_SL_COMMENT=9;
    public static final int EOF=-1;
    public static final int RULE_DOUBLE=6;
    public static final int RULE_ML_COMMENT=8;
    public static final int T__19=19;
    public static final int RULE_STRING=5;
    public static final int T__16=16;
    public static final int T__15=15;
    public static final int T__18=18;
    public static final int T__17=17;
    public static final int T__12=12;
    public static final int T__14=14;
    public static final int T__13=13;
    public static final int RULE_INT=7;
    public static final int RULE_WS=10;

    // delegates
    // delegators


        public InternalDomoticDslParser(TokenStream input) {
            this(input, new RecognizerSharedState());
        }
        public InternalDomoticDslParser(TokenStream input, RecognizerSharedState state) {
            super(input, state);
             
        }
        

    public String[] getTokenNames() { return InternalDomoticDslParser.tokenNames; }
    public String getGrammarFileName() { return "../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g"; }



     	private DomoticDslGrammarAccess grammarAccess;
     	
        public InternalDomoticDslParser(TokenStream input, DomoticDslGrammarAccess grammarAccess) {
            this(input);
            this.grammarAccess = grammarAccess;
            registerRules(grammarAccess.getGrammar());
        }
        
        @Override
        protected String getFirstRuleName() {
        	return "System";	
       	}
       	
       	@Override
       	protected DomoticDslGrammarAccess getGrammarAccess() {
       		return grammarAccess;
       	}



    // $ANTLR start "entryRuleSystem"
    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:68:1: entryRuleSystem returns [EObject current=null] : iv_ruleSystem= ruleSystem EOF ;
    public final EObject entryRuleSystem() throws RecognitionException {
        EObject current = null;

        EObject iv_ruleSystem = null;


        try {
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:69:2: (iv_ruleSystem= ruleSystem EOF )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:70:2: iv_ruleSystem= ruleSystem EOF
            {
             newCompositeNode(grammarAccess.getSystemRule()); 
            pushFollow(FOLLOW_ruleSystem_in_entryRuleSystem75);
            iv_ruleSystem=ruleSystem();

            state._fsp--;

             current =iv_ruleSystem; 
            match(input,EOF,FOLLOW_EOF_in_entryRuleSystem85); 

            }

        }
         
            catch (RecognitionException re) { 
                recover(input,re); 
                appendSkippedTokens();
            } 
        finally {
        }
        return current;
    }
    // $ANTLR end "entryRuleSystem"


    // $ANTLR start "ruleSystem"
    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:77:1: ruleSystem returns [EObject current=null] : (otherlv_0= 'DomoticSystem' ( (lv_name_1_0= RULE_ID ) ) ( (lv_package_2_0= rulePackage ) )? otherlv_3= ';' ( (lv_properties_4_0= ruleProperties ) )? ( (lv_elettrodomestico_5_0= ruleElettrodomestico ) )* ( (lv_sensors_6_0= ruleSensor ) )* ) ;
    public final EObject ruleSystem() throws RecognitionException {
        EObject current = null;

        Token otherlv_0=null;
        Token lv_name_1_0=null;
        Token otherlv_3=null;
        EObject lv_package_2_0 = null;

        EObject lv_properties_4_0 = null;

        EObject lv_elettrodomestico_5_0 = null;

        EObject lv_sensors_6_0 = null;


         enterRule(); 
            
        try {
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:80:28: ( (otherlv_0= 'DomoticSystem' ( (lv_name_1_0= RULE_ID ) ) ( (lv_package_2_0= rulePackage ) )? otherlv_3= ';' ( (lv_properties_4_0= ruleProperties ) )? ( (lv_elettrodomestico_5_0= ruleElettrodomestico ) )* ( (lv_sensors_6_0= ruleSensor ) )* ) )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:81:1: (otherlv_0= 'DomoticSystem' ( (lv_name_1_0= RULE_ID ) ) ( (lv_package_2_0= rulePackage ) )? otherlv_3= ';' ( (lv_properties_4_0= ruleProperties ) )? ( (lv_elettrodomestico_5_0= ruleElettrodomestico ) )* ( (lv_sensors_6_0= ruleSensor ) )* )
            {
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:81:1: (otherlv_0= 'DomoticSystem' ( (lv_name_1_0= RULE_ID ) ) ( (lv_package_2_0= rulePackage ) )? otherlv_3= ';' ( (lv_properties_4_0= ruleProperties ) )? ( (lv_elettrodomestico_5_0= ruleElettrodomestico ) )* ( (lv_sensors_6_0= ruleSensor ) )* )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:81:3: otherlv_0= 'DomoticSystem' ( (lv_name_1_0= RULE_ID ) ) ( (lv_package_2_0= rulePackage ) )? otherlv_3= ';' ( (lv_properties_4_0= ruleProperties ) )? ( (lv_elettrodomestico_5_0= ruleElettrodomestico ) )* ( (lv_sensors_6_0= ruleSensor ) )*
            {
            otherlv_0=(Token)match(input,12,FOLLOW_12_in_ruleSystem122); 

                	newLeafNode(otherlv_0, grammarAccess.getSystemAccess().getDomoticSystemKeyword_0());
                
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:85:1: ( (lv_name_1_0= RULE_ID ) )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:86:1: (lv_name_1_0= RULE_ID )
            {
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:86:1: (lv_name_1_0= RULE_ID )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:87:3: lv_name_1_0= RULE_ID
            {
            lv_name_1_0=(Token)match(input,RULE_ID,FOLLOW_RULE_ID_in_ruleSystem139); 

            			newLeafNode(lv_name_1_0, grammarAccess.getSystemAccess().getNameIDTerminalRuleCall_1_0()); 
            		

            	        if (current==null) {
            	            current = createModelElement(grammarAccess.getSystemRule());
            	        }
                   		setWithLastConsumed(
                   			current, 
                   			"name",
                    		lv_name_1_0, 
                    		"ID");
            	    

            }


            }

            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:103:2: ( (lv_package_2_0= rulePackage ) )?
            int alt1=2;
            int LA1_0 = input.LA(1);

            if ( (LA1_0==14) ) {
                alt1=1;
            }
            switch (alt1) {
                case 1 :
                    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:104:1: (lv_package_2_0= rulePackage )
                    {
                    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:104:1: (lv_package_2_0= rulePackage )
                    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:105:3: lv_package_2_0= rulePackage
                    {
                     
                    	        newCompositeNode(grammarAccess.getSystemAccess().getPackagePackageParserRuleCall_2_0()); 
                    	    
                    pushFollow(FOLLOW_rulePackage_in_ruleSystem165);
                    lv_package_2_0=rulePackage();

                    state._fsp--;


                    	        if (current==null) {
                    	            current = createModelElementForParent(grammarAccess.getSystemRule());
                    	        }
                           		set(
                           			current, 
                           			"package",
                            		lv_package_2_0, 
                            		"Package");
                    	        afterParserOrEnumRuleCall();
                    	    

                    }


                    }
                    break;

            }

            otherlv_3=(Token)match(input,13,FOLLOW_13_in_ruleSystem178); 

                	newLeafNode(otherlv_3, grammarAccess.getSystemAccess().getSemicolonKeyword_3());
                
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:125:1: ( (lv_properties_4_0= ruleProperties ) )?
            int alt2=2;
            int LA2_0 = input.LA(1);

            if ( (LA2_0==15) ) {
                alt2=1;
            }
            switch (alt2) {
                case 1 :
                    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:126:1: (lv_properties_4_0= ruleProperties )
                    {
                    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:126:1: (lv_properties_4_0= ruleProperties )
                    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:127:3: lv_properties_4_0= ruleProperties
                    {
                     
                    	        newCompositeNode(grammarAccess.getSystemAccess().getPropertiesPropertiesParserRuleCall_4_0()); 
                    	    
                    pushFollow(FOLLOW_ruleProperties_in_ruleSystem199);
                    lv_properties_4_0=ruleProperties();

                    state._fsp--;


                    	        if (current==null) {
                    	            current = createModelElementForParent(grammarAccess.getSystemRule());
                    	        }
                           		set(
                           			current, 
                           			"properties",
                            		lv_properties_4_0, 
                            		"Properties");
                    	        afterParserOrEnumRuleCall();
                    	    

                    }


                    }
                    break;

            }

            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:143:3: ( (lv_elettrodomestico_5_0= ruleElettrodomestico ) )*
            loop3:
            do {
                int alt3=2;
                int LA3_0 = input.LA(1);

                if ( (LA3_0==16) ) {
                    alt3=1;
                }


                switch (alt3) {
            	case 1 :
            	    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:144:1: (lv_elettrodomestico_5_0= ruleElettrodomestico )
            	    {
            	    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:144:1: (lv_elettrodomestico_5_0= ruleElettrodomestico )
            	    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:145:3: lv_elettrodomestico_5_0= ruleElettrodomestico
            	    {
            	     
            	    	        newCompositeNode(grammarAccess.getSystemAccess().getElettrodomesticoElettrodomesticoParserRuleCall_5_0()); 
            	    	    
            	    pushFollow(FOLLOW_ruleElettrodomestico_in_ruleSystem221);
            	    lv_elettrodomestico_5_0=ruleElettrodomestico();

            	    state._fsp--;


            	    	        if (current==null) {
            	    	            current = createModelElementForParent(grammarAccess.getSystemRule());
            	    	        }
            	           		add(
            	           			current, 
            	           			"elettrodomestico",
            	            		lv_elettrodomestico_5_0, 
            	            		"Elettrodomestico");
            	    	        afterParserOrEnumRuleCall();
            	    	    

            	    }


            	    }
            	    break;

            	default :
            	    break loop3;
                }
            } while (true);

            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:161:3: ( (lv_sensors_6_0= ruleSensor ) )*
            loop4:
            do {
                int alt4=2;
                int LA4_0 = input.LA(1);

                if ( (LA4_0==19) ) {
                    alt4=1;
                }


                switch (alt4) {
            	case 1 :
            	    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:162:1: (lv_sensors_6_0= ruleSensor )
            	    {
            	    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:162:1: (lv_sensors_6_0= ruleSensor )
            	    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:163:3: lv_sensors_6_0= ruleSensor
            	    {
            	     
            	    	        newCompositeNode(grammarAccess.getSystemAccess().getSensorsSensorParserRuleCall_6_0()); 
            	    	    
            	    pushFollow(FOLLOW_ruleSensor_in_ruleSystem243);
            	    lv_sensors_6_0=ruleSensor();

            	    state._fsp--;


            	    	        if (current==null) {
            	    	            current = createModelElementForParent(grammarAccess.getSystemRule());
            	    	        }
            	           		add(
            	           			current, 
            	           			"sensors",
            	            		lv_sensors_6_0, 
            	            		"Sensor");
            	    	        afterParserOrEnumRuleCall();
            	    	    

            	    }


            	    }
            	    break;

            	default :
            	    break loop4;
                }
            } while (true);


            }


            }

             leaveRule(); 
        }
         
            catch (RecognitionException re) { 
                recover(input,re); 
                appendSkippedTokens();
            } 
        finally {
        }
        return current;
    }
    // $ANTLR end "ruleSystem"


    // $ANTLR start "entryRulePackage"
    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:187:1: entryRulePackage returns [EObject current=null] : iv_rulePackage= rulePackage EOF ;
    public final EObject entryRulePackage() throws RecognitionException {
        EObject current = null;

        EObject iv_rulePackage = null;


        try {
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:188:2: (iv_rulePackage= rulePackage EOF )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:189:2: iv_rulePackage= rulePackage EOF
            {
             newCompositeNode(grammarAccess.getPackageRule()); 
            pushFollow(FOLLOW_rulePackage_in_entryRulePackage280);
            iv_rulePackage=rulePackage();

            state._fsp--;

             current =iv_rulePackage; 
            match(input,EOF,FOLLOW_EOF_in_entryRulePackage290); 

            }

        }
         
            catch (RecognitionException re) { 
                recover(input,re); 
                appendSkippedTokens();
            } 
        finally {
        }
        return current;
    }
    // $ANTLR end "entryRulePackage"


    // $ANTLR start "rulePackage"
    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:196:1: rulePackage returns [EObject current=null] : (otherlv_0= 'package' ( (lv_name_1_0= RULE_STRING ) ) ) ;
    public final EObject rulePackage() throws RecognitionException {
        EObject current = null;

        Token otherlv_0=null;
        Token lv_name_1_0=null;

         enterRule(); 
            
        try {
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:199:28: ( (otherlv_0= 'package' ( (lv_name_1_0= RULE_STRING ) ) ) )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:200:1: (otherlv_0= 'package' ( (lv_name_1_0= RULE_STRING ) ) )
            {
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:200:1: (otherlv_0= 'package' ( (lv_name_1_0= RULE_STRING ) ) )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:200:3: otherlv_0= 'package' ( (lv_name_1_0= RULE_STRING ) )
            {
            otherlv_0=(Token)match(input,14,FOLLOW_14_in_rulePackage327); 

                	newLeafNode(otherlv_0, grammarAccess.getPackageAccess().getPackageKeyword_0());
                
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:204:1: ( (lv_name_1_0= RULE_STRING ) )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:205:1: (lv_name_1_0= RULE_STRING )
            {
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:205:1: (lv_name_1_0= RULE_STRING )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:206:3: lv_name_1_0= RULE_STRING
            {
            lv_name_1_0=(Token)match(input,RULE_STRING,FOLLOW_RULE_STRING_in_rulePackage344); 

            			newLeafNode(lv_name_1_0, grammarAccess.getPackageAccess().getNameSTRINGTerminalRuleCall_1_0()); 
            		

            	        if (current==null) {
            	            current = createModelElement(grammarAccess.getPackageRule());
            	        }
                   		setWithLastConsumed(
                   			current, 
                   			"name",
                    		lv_name_1_0, 
                    		"STRING");
            	    

            }


            }


            }


            }

             leaveRule(); 
        }
         
            catch (RecognitionException re) { 
                recover(input,re); 
                appendSkippedTokens();
            } 
        finally {
        }
        return current;
    }
    // $ANTLR end "rulePackage"


    // $ANTLR start "entryRuleProperties"
    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:230:1: entryRuleProperties returns [EObject current=null] : iv_ruleProperties= ruleProperties EOF ;
    public final EObject entryRuleProperties() throws RecognitionException {
        EObject current = null;

        EObject iv_ruleProperties = null;


        try {
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:231:2: (iv_ruleProperties= ruleProperties EOF )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:232:2: iv_ruleProperties= ruleProperties EOF
            {
             newCompositeNode(grammarAccess.getPropertiesRule()); 
            pushFollow(FOLLOW_ruleProperties_in_entryRuleProperties385);
            iv_ruleProperties=ruleProperties();

            state._fsp--;

             current =iv_ruleProperties; 
            match(input,EOF,FOLLOW_EOF_in_entryRuleProperties395); 

            }

        }
         
            catch (RecognitionException re) { 
                recover(input,re); 
                appendSkippedTokens();
            } 
        finally {
        }
        return current;
    }
    // $ANTLR end "entryRuleProperties"


    // $ANTLR start "ruleProperties"
    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:239:1: ruleProperties returns [EObject current=null] : (otherlv_0= 'propertiesPath=' ( (lv_name_1_0= RULE_STRING ) ) otherlv_2= ';' ) ;
    public final EObject ruleProperties() throws RecognitionException {
        EObject current = null;

        Token otherlv_0=null;
        Token lv_name_1_0=null;
        Token otherlv_2=null;

         enterRule(); 
            
        try {
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:242:28: ( (otherlv_0= 'propertiesPath=' ( (lv_name_1_0= RULE_STRING ) ) otherlv_2= ';' ) )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:243:1: (otherlv_0= 'propertiesPath=' ( (lv_name_1_0= RULE_STRING ) ) otherlv_2= ';' )
            {
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:243:1: (otherlv_0= 'propertiesPath=' ( (lv_name_1_0= RULE_STRING ) ) otherlv_2= ';' )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:243:3: otherlv_0= 'propertiesPath=' ( (lv_name_1_0= RULE_STRING ) ) otherlv_2= ';'
            {
            otherlv_0=(Token)match(input,15,FOLLOW_15_in_ruleProperties432); 

                	newLeafNode(otherlv_0, grammarAccess.getPropertiesAccess().getPropertiesPathKeyword_0());
                
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:247:1: ( (lv_name_1_0= RULE_STRING ) )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:248:1: (lv_name_1_0= RULE_STRING )
            {
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:248:1: (lv_name_1_0= RULE_STRING )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:249:3: lv_name_1_0= RULE_STRING
            {
            lv_name_1_0=(Token)match(input,RULE_STRING,FOLLOW_RULE_STRING_in_ruleProperties449); 

            			newLeafNode(lv_name_1_0, grammarAccess.getPropertiesAccess().getNameSTRINGTerminalRuleCall_1_0()); 
            		

            	        if (current==null) {
            	            current = createModelElement(grammarAccess.getPropertiesRule());
            	        }
                   		setWithLastConsumed(
                   			current, 
                   			"name",
                    		lv_name_1_0, 
                    		"STRING");
            	    

            }


            }

            otherlv_2=(Token)match(input,13,FOLLOW_13_in_ruleProperties466); 

                	newLeafNode(otherlv_2, grammarAccess.getPropertiesAccess().getSemicolonKeyword_2());
                

            }


            }

             leaveRule(); 
        }
         
            catch (RecognitionException re) { 
                recover(input,re); 
                appendSkippedTokens();
            } 
        finally {
        }
        return current;
    }
    // $ANTLR end "ruleProperties"


    // $ANTLR start "entryRuleElettrodomestico"
    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:277:1: entryRuleElettrodomestico returns [EObject current=null] : iv_ruleElettrodomestico= ruleElettrodomestico EOF ;
    public final EObject entryRuleElettrodomestico() throws RecognitionException {
        EObject current = null;

        EObject iv_ruleElettrodomestico = null;


        try {
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:278:2: (iv_ruleElettrodomestico= ruleElettrodomestico EOF )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:279:2: iv_ruleElettrodomestico= ruleElettrodomestico EOF
            {
             newCompositeNode(grammarAccess.getElettrodomesticoRule()); 
            pushFollow(FOLLOW_ruleElettrodomestico_in_entryRuleElettrodomestico502);
            iv_ruleElettrodomestico=ruleElettrodomestico();

            state._fsp--;

             current =iv_ruleElettrodomestico; 
            match(input,EOF,FOLLOW_EOF_in_entryRuleElettrodomestico512); 

            }

        }
         
            catch (RecognitionException re) { 
                recover(input,re); 
                appendSkippedTokens();
            } 
        finally {
        }
        return current;
    }
    // $ANTLR end "entryRuleElettrodomestico"


    // $ANTLR start "ruleElettrodomestico"
    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:286:1: ruleElettrodomestico returns [EObject current=null] : (otherlv_0= 'Elettrodomestico' ( (lv_name_1_0= RULE_ID ) ) otherlv_2= 'consumption=' ( (lv_consumption_3_0= ruleConsumption ) ) otherlv_4= 'usage=' ( (lv_usage_5_0= ruleUsage ) ) otherlv_6= ';' ) ;
    public final EObject ruleElettrodomestico() throws RecognitionException {
        EObject current = null;

        Token otherlv_0=null;
        Token lv_name_1_0=null;
        Token otherlv_2=null;
        Token otherlv_4=null;
        Token otherlv_6=null;
        Enumerator lv_consumption_3_0 = null;

        Enumerator lv_usage_5_0 = null;


         enterRule(); 
            
        try {
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:289:28: ( (otherlv_0= 'Elettrodomestico' ( (lv_name_1_0= RULE_ID ) ) otherlv_2= 'consumption=' ( (lv_consumption_3_0= ruleConsumption ) ) otherlv_4= 'usage=' ( (lv_usage_5_0= ruleUsage ) ) otherlv_6= ';' ) )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:290:1: (otherlv_0= 'Elettrodomestico' ( (lv_name_1_0= RULE_ID ) ) otherlv_2= 'consumption=' ( (lv_consumption_3_0= ruleConsumption ) ) otherlv_4= 'usage=' ( (lv_usage_5_0= ruleUsage ) ) otherlv_6= ';' )
            {
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:290:1: (otherlv_0= 'Elettrodomestico' ( (lv_name_1_0= RULE_ID ) ) otherlv_2= 'consumption=' ( (lv_consumption_3_0= ruleConsumption ) ) otherlv_4= 'usage=' ( (lv_usage_5_0= ruleUsage ) ) otherlv_6= ';' )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:290:3: otherlv_0= 'Elettrodomestico' ( (lv_name_1_0= RULE_ID ) ) otherlv_2= 'consumption=' ( (lv_consumption_3_0= ruleConsumption ) ) otherlv_4= 'usage=' ( (lv_usage_5_0= ruleUsage ) ) otherlv_6= ';'
            {
            otherlv_0=(Token)match(input,16,FOLLOW_16_in_ruleElettrodomestico549); 

                	newLeafNode(otherlv_0, grammarAccess.getElettrodomesticoAccess().getElettrodomesticoKeyword_0());
                
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:294:1: ( (lv_name_1_0= RULE_ID ) )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:295:1: (lv_name_1_0= RULE_ID )
            {
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:295:1: (lv_name_1_0= RULE_ID )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:296:3: lv_name_1_0= RULE_ID
            {
            lv_name_1_0=(Token)match(input,RULE_ID,FOLLOW_RULE_ID_in_ruleElettrodomestico566); 

            			newLeafNode(lv_name_1_0, grammarAccess.getElettrodomesticoAccess().getNameIDTerminalRuleCall_1_0()); 
            		

            	        if (current==null) {
            	            current = createModelElement(grammarAccess.getElettrodomesticoRule());
            	        }
                   		setWithLastConsumed(
                   			current, 
                   			"name",
                    		lv_name_1_0, 
                    		"ID");
            	    

            }


            }

            otherlv_2=(Token)match(input,17,FOLLOW_17_in_ruleElettrodomestico583); 

                	newLeafNode(otherlv_2, grammarAccess.getElettrodomesticoAccess().getConsumptionKeyword_2());
                
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:316:1: ( (lv_consumption_3_0= ruleConsumption ) )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:317:1: (lv_consumption_3_0= ruleConsumption )
            {
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:317:1: (lv_consumption_3_0= ruleConsumption )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:318:3: lv_consumption_3_0= ruleConsumption
            {
             
            	        newCompositeNode(grammarAccess.getElettrodomesticoAccess().getConsumptionConsumptionEnumRuleCall_3_0()); 
            	    
            pushFollow(FOLLOW_ruleConsumption_in_ruleElettrodomestico604);
            lv_consumption_3_0=ruleConsumption();

            state._fsp--;


            	        if (current==null) {
            	            current = createModelElementForParent(grammarAccess.getElettrodomesticoRule());
            	        }
                   		set(
                   			current, 
                   			"consumption",
                    		lv_consumption_3_0, 
                    		"Consumption");
            	        afterParserOrEnumRuleCall();
            	    

            }


            }

            otherlv_4=(Token)match(input,18,FOLLOW_18_in_ruleElettrodomestico616); 

                	newLeafNode(otherlv_4, grammarAccess.getElettrodomesticoAccess().getUsageKeyword_4());
                
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:338:1: ( (lv_usage_5_0= ruleUsage ) )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:339:1: (lv_usage_5_0= ruleUsage )
            {
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:339:1: (lv_usage_5_0= ruleUsage )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:340:3: lv_usage_5_0= ruleUsage
            {
             
            	        newCompositeNode(grammarAccess.getElettrodomesticoAccess().getUsageUsageEnumRuleCall_5_0()); 
            	    
            pushFollow(FOLLOW_ruleUsage_in_ruleElettrodomestico637);
            lv_usage_5_0=ruleUsage();

            state._fsp--;


            	        if (current==null) {
            	            current = createModelElementForParent(grammarAccess.getElettrodomesticoRule());
            	        }
                   		set(
                   			current, 
                   			"usage",
                    		lv_usage_5_0, 
                    		"Usage");
            	        afterParserOrEnumRuleCall();
            	    

            }


            }

            otherlv_6=(Token)match(input,13,FOLLOW_13_in_ruleElettrodomestico649); 

                	newLeafNode(otherlv_6, grammarAccess.getElettrodomesticoAccess().getSemicolonKeyword_6());
                

            }


            }

             leaveRule(); 
        }
         
            catch (RecognitionException re) { 
                recover(input,re); 
                appendSkippedTokens();
            } 
        finally {
        }
        return current;
    }
    // $ANTLR end "ruleElettrodomestico"


    // $ANTLR start "entryRuleSensor"
    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:368:1: entryRuleSensor returns [EObject current=null] : iv_ruleSensor= ruleSensor EOF ;
    public final EObject entryRuleSensor() throws RecognitionException {
        EObject current = null;

        EObject iv_ruleSensor = null;


        try {
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:369:2: (iv_ruleSensor= ruleSensor EOF )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:370:2: iv_ruleSensor= ruleSensor EOF
            {
             newCompositeNode(grammarAccess.getSensorRule()); 
            pushFollow(FOLLOW_ruleSensor_in_entryRuleSensor685);
            iv_ruleSensor=ruleSensor();

            state._fsp--;

             current =iv_ruleSensor; 
            match(input,EOF,FOLLOW_EOF_in_entryRuleSensor695); 

            }

        }
         
            catch (RecognitionException re) { 
                recover(input,re); 
                appendSkippedTokens();
            } 
        finally {
        }
        return current;
    }
    // $ANTLR end "entryRuleSensor"


    // $ANTLR start "ruleSensor"
    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:377:1: ruleSensor returns [EObject current=null] : (otherlv_0= 'Sensor' otherlv_1= 'for' ( (otherlv_2= RULE_ID ) ) (otherlv_3= 'minConsumption=' ( (lv_minConsumption_4_0= RULE_DOUBLE ) ) otherlv_5= 'maxConsumption=' ( (lv_maxConsumption_6_0= RULE_DOUBLE ) ) )? otherlv_7= ';' ) ;
    public final EObject ruleSensor() throws RecognitionException {
        EObject current = null;

        Token otherlv_0=null;
        Token otherlv_1=null;
        Token otherlv_2=null;
        Token otherlv_3=null;
        Token lv_minConsumption_4_0=null;
        Token otherlv_5=null;
        Token lv_maxConsumption_6_0=null;
        Token otherlv_7=null;

         enterRule(); 
            
        try {
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:380:28: ( (otherlv_0= 'Sensor' otherlv_1= 'for' ( (otherlv_2= RULE_ID ) ) (otherlv_3= 'minConsumption=' ( (lv_minConsumption_4_0= RULE_DOUBLE ) ) otherlv_5= 'maxConsumption=' ( (lv_maxConsumption_6_0= RULE_DOUBLE ) ) )? otherlv_7= ';' ) )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:381:1: (otherlv_0= 'Sensor' otherlv_1= 'for' ( (otherlv_2= RULE_ID ) ) (otherlv_3= 'minConsumption=' ( (lv_minConsumption_4_0= RULE_DOUBLE ) ) otherlv_5= 'maxConsumption=' ( (lv_maxConsumption_6_0= RULE_DOUBLE ) ) )? otherlv_7= ';' )
            {
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:381:1: (otherlv_0= 'Sensor' otherlv_1= 'for' ( (otherlv_2= RULE_ID ) ) (otherlv_3= 'minConsumption=' ( (lv_minConsumption_4_0= RULE_DOUBLE ) ) otherlv_5= 'maxConsumption=' ( (lv_maxConsumption_6_0= RULE_DOUBLE ) ) )? otherlv_7= ';' )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:381:3: otherlv_0= 'Sensor' otherlv_1= 'for' ( (otherlv_2= RULE_ID ) ) (otherlv_3= 'minConsumption=' ( (lv_minConsumption_4_0= RULE_DOUBLE ) ) otherlv_5= 'maxConsumption=' ( (lv_maxConsumption_6_0= RULE_DOUBLE ) ) )? otherlv_7= ';'
            {
            otherlv_0=(Token)match(input,19,FOLLOW_19_in_ruleSensor732); 

                	newLeafNode(otherlv_0, grammarAccess.getSensorAccess().getSensorKeyword_0());
                
            otherlv_1=(Token)match(input,20,FOLLOW_20_in_ruleSensor744); 

                	newLeafNode(otherlv_1, grammarAccess.getSensorAccess().getForKeyword_1());
                
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:389:1: ( (otherlv_2= RULE_ID ) )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:390:1: (otherlv_2= RULE_ID )
            {
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:390:1: (otherlv_2= RULE_ID )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:391:3: otherlv_2= RULE_ID
            {

            			if (current==null) {
            	            current = createModelElement(grammarAccess.getSensorRule());
            	        }
                    
            otherlv_2=(Token)match(input,RULE_ID,FOLLOW_RULE_ID_in_ruleSensor764); 

            		newLeafNode(otherlv_2, grammarAccess.getSensorAccess().getElettrodomesticoElettrodomesticoCrossReference_2_0()); 
            	

            }


            }

            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:402:2: (otherlv_3= 'minConsumption=' ( (lv_minConsumption_4_0= RULE_DOUBLE ) ) otherlv_5= 'maxConsumption=' ( (lv_maxConsumption_6_0= RULE_DOUBLE ) ) )?
            int alt5=2;
            int LA5_0 = input.LA(1);

            if ( (LA5_0==21) ) {
                alt5=1;
            }
            switch (alt5) {
                case 1 :
                    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:402:4: otherlv_3= 'minConsumption=' ( (lv_minConsumption_4_0= RULE_DOUBLE ) ) otherlv_5= 'maxConsumption=' ( (lv_maxConsumption_6_0= RULE_DOUBLE ) )
                    {
                    otherlv_3=(Token)match(input,21,FOLLOW_21_in_ruleSensor777); 

                        	newLeafNode(otherlv_3, grammarAccess.getSensorAccess().getMinConsumptionKeyword_3_0());
                        
                    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:406:1: ( (lv_minConsumption_4_0= RULE_DOUBLE ) )
                    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:407:1: (lv_minConsumption_4_0= RULE_DOUBLE )
                    {
                    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:407:1: (lv_minConsumption_4_0= RULE_DOUBLE )
                    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:408:3: lv_minConsumption_4_0= RULE_DOUBLE
                    {
                    lv_minConsumption_4_0=(Token)match(input,RULE_DOUBLE,FOLLOW_RULE_DOUBLE_in_ruleSensor794); 

                    			newLeafNode(lv_minConsumption_4_0, grammarAccess.getSensorAccess().getMinConsumptionDOUBLETerminalRuleCall_3_1_0()); 
                    		

                    	        if (current==null) {
                    	            current = createModelElement(grammarAccess.getSensorRule());
                    	        }
                           		setWithLastConsumed(
                           			current, 
                           			"minConsumption",
                            		lv_minConsumption_4_0, 
                            		"DOUBLE");
                    	    

                    }


                    }

                    otherlv_5=(Token)match(input,22,FOLLOW_22_in_ruleSensor811); 

                        	newLeafNode(otherlv_5, grammarAccess.getSensorAccess().getMaxConsumptionKeyword_3_2());
                        
                    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:428:1: ( (lv_maxConsumption_6_0= RULE_DOUBLE ) )
                    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:429:1: (lv_maxConsumption_6_0= RULE_DOUBLE )
                    {
                    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:429:1: (lv_maxConsumption_6_0= RULE_DOUBLE )
                    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:430:3: lv_maxConsumption_6_0= RULE_DOUBLE
                    {
                    lv_maxConsumption_6_0=(Token)match(input,RULE_DOUBLE,FOLLOW_RULE_DOUBLE_in_ruleSensor828); 

                    			newLeafNode(lv_maxConsumption_6_0, grammarAccess.getSensorAccess().getMaxConsumptionDOUBLETerminalRuleCall_3_3_0()); 
                    		

                    	        if (current==null) {
                    	            current = createModelElement(grammarAccess.getSensorRule());
                    	        }
                           		setWithLastConsumed(
                           			current, 
                           			"maxConsumption",
                            		lv_maxConsumption_6_0, 
                            		"DOUBLE");
                    	    

                    }


                    }


                    }
                    break;

            }

            otherlv_7=(Token)match(input,13,FOLLOW_13_in_ruleSensor847); 

                	newLeafNode(otherlv_7, grammarAccess.getSensorAccess().getSemicolonKeyword_4());
                

            }


            }

             leaveRule(); 
        }
         
            catch (RecognitionException re) { 
                recover(input,re); 
                appendSkippedTokens();
            } 
        finally {
        }
        return current;
    }
    // $ANTLR end "ruleSensor"


    // $ANTLR start "ruleConsumption"
    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:458:1: ruleConsumption returns [Enumerator current=null] : ( (enumLiteral_0= 'LOW' ) | (enumLiteral_1= 'MEDIUM' ) | (enumLiteral_2= 'HIGH' ) ) ;
    public final Enumerator ruleConsumption() throws RecognitionException {
        Enumerator current = null;

        Token enumLiteral_0=null;
        Token enumLiteral_1=null;
        Token enumLiteral_2=null;

         enterRule(); 
        try {
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:460:28: ( ( (enumLiteral_0= 'LOW' ) | (enumLiteral_1= 'MEDIUM' ) | (enumLiteral_2= 'HIGH' ) ) )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:461:1: ( (enumLiteral_0= 'LOW' ) | (enumLiteral_1= 'MEDIUM' ) | (enumLiteral_2= 'HIGH' ) )
            {
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:461:1: ( (enumLiteral_0= 'LOW' ) | (enumLiteral_1= 'MEDIUM' ) | (enumLiteral_2= 'HIGH' ) )
            int alt6=3;
            switch ( input.LA(1) ) {
            case 23:
                {
                alt6=1;
                }
                break;
            case 24:
                {
                alt6=2;
                }
                break;
            case 25:
                {
                alt6=3;
                }
                break;
            default:
                NoViableAltException nvae =
                    new NoViableAltException("", 6, 0, input);

                throw nvae;
            }

            switch (alt6) {
                case 1 :
                    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:461:2: (enumLiteral_0= 'LOW' )
                    {
                    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:461:2: (enumLiteral_0= 'LOW' )
                    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:461:4: enumLiteral_0= 'LOW'
                    {
                    enumLiteral_0=(Token)match(input,23,FOLLOW_23_in_ruleConsumption897); 

                            current = grammarAccess.getConsumptionAccess().getLOWEnumLiteralDeclaration_0().getEnumLiteral().getInstance();
                            newLeafNode(enumLiteral_0, grammarAccess.getConsumptionAccess().getLOWEnumLiteralDeclaration_0()); 
                        

                    }


                    }
                    break;
                case 2 :
                    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:467:6: (enumLiteral_1= 'MEDIUM' )
                    {
                    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:467:6: (enumLiteral_1= 'MEDIUM' )
                    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:467:8: enumLiteral_1= 'MEDIUM'
                    {
                    enumLiteral_1=(Token)match(input,24,FOLLOW_24_in_ruleConsumption914); 

                            current = grammarAccess.getConsumptionAccess().getMEDIUMEnumLiteralDeclaration_1().getEnumLiteral().getInstance();
                            newLeafNode(enumLiteral_1, grammarAccess.getConsumptionAccess().getMEDIUMEnumLiteralDeclaration_1()); 
                        

                    }


                    }
                    break;
                case 3 :
                    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:473:6: (enumLiteral_2= 'HIGH' )
                    {
                    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:473:6: (enumLiteral_2= 'HIGH' )
                    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:473:8: enumLiteral_2= 'HIGH'
                    {
                    enumLiteral_2=(Token)match(input,25,FOLLOW_25_in_ruleConsumption931); 

                            current = grammarAccess.getConsumptionAccess().getHIGHEnumLiteralDeclaration_2().getEnumLiteral().getInstance();
                            newLeafNode(enumLiteral_2, grammarAccess.getConsumptionAccess().getHIGHEnumLiteralDeclaration_2()); 
                        

                    }


                    }
                    break;

            }


            }

             leaveRule(); 
        }
         
            catch (RecognitionException re) { 
                recover(input,re); 
                appendSkippedTokens();
            } 
        finally {
        }
        return current;
    }
    // $ANTLR end "ruleConsumption"


    // $ANTLR start "ruleUsage"
    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:483:1: ruleUsage returns [Enumerator current=null] : ( (enumLiteral_0= 'ESSENTIAL' ) | (enumLiteral_1= 'OPTIONAL' ) ) ;
    public final Enumerator ruleUsage() throws RecognitionException {
        Enumerator current = null;

        Token enumLiteral_0=null;
        Token enumLiteral_1=null;

         enterRule(); 
        try {
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:485:28: ( ( (enumLiteral_0= 'ESSENTIAL' ) | (enumLiteral_1= 'OPTIONAL' ) ) )
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:486:1: ( (enumLiteral_0= 'ESSENTIAL' ) | (enumLiteral_1= 'OPTIONAL' ) )
            {
            // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:486:1: ( (enumLiteral_0= 'ESSENTIAL' ) | (enumLiteral_1= 'OPTIONAL' ) )
            int alt7=2;
            int LA7_0 = input.LA(1);

            if ( (LA7_0==26) ) {
                alt7=1;
            }
            else if ( (LA7_0==27) ) {
                alt7=2;
            }
            else {
                NoViableAltException nvae =
                    new NoViableAltException("", 7, 0, input);

                throw nvae;
            }
            switch (alt7) {
                case 1 :
                    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:486:2: (enumLiteral_0= 'ESSENTIAL' )
                    {
                    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:486:2: (enumLiteral_0= 'ESSENTIAL' )
                    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:486:4: enumLiteral_0= 'ESSENTIAL'
                    {
                    enumLiteral_0=(Token)match(input,26,FOLLOW_26_in_ruleUsage976); 

                            current = grammarAccess.getUsageAccess().getESSENTIALEnumLiteralDeclaration_0().getEnumLiteral().getInstance();
                            newLeafNode(enumLiteral_0, grammarAccess.getUsageAccess().getESSENTIALEnumLiteralDeclaration_0()); 
                        

                    }


                    }
                    break;
                case 2 :
                    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:492:6: (enumLiteral_1= 'OPTIONAL' )
                    {
                    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:492:6: (enumLiteral_1= 'OPTIONAL' )
                    // ../domotica.dsl/src-gen/it/unibo/iss/domotica/parser/antlr/internal/InternalDomoticDsl.g:492:8: enumLiteral_1= 'OPTIONAL'
                    {
                    enumLiteral_1=(Token)match(input,27,FOLLOW_27_in_ruleUsage993); 

                            current = grammarAccess.getUsageAccess().getOPTIONALEnumLiteralDeclaration_1().getEnumLiteral().getInstance();
                            newLeafNode(enumLiteral_1, grammarAccess.getUsageAccess().getOPTIONALEnumLiteralDeclaration_1()); 
                        

                    }


                    }
                    break;

            }


            }

             leaveRule(); 
        }
         
            catch (RecognitionException re) { 
                recover(input,re); 
                appendSkippedTokens();
            } 
        finally {
        }
        return current;
    }
    // $ANTLR end "ruleUsage"

    // Delegated rules


 

    public static final BitSet FOLLOW_ruleSystem_in_entryRuleSystem75 = new BitSet(new long[]{0x0000000000000000L});
    public static final BitSet FOLLOW_EOF_in_entryRuleSystem85 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_12_in_ruleSystem122 = new BitSet(new long[]{0x0000000000000010L});
    public static final BitSet FOLLOW_RULE_ID_in_ruleSystem139 = new BitSet(new long[]{0x0000000000006000L});
    public static final BitSet FOLLOW_rulePackage_in_ruleSystem165 = new BitSet(new long[]{0x0000000000002000L});
    public static final BitSet FOLLOW_13_in_ruleSystem178 = new BitSet(new long[]{0x0000000000098002L});
    public static final BitSet FOLLOW_ruleProperties_in_ruleSystem199 = new BitSet(new long[]{0x0000000000090002L});
    public static final BitSet FOLLOW_ruleElettrodomestico_in_ruleSystem221 = new BitSet(new long[]{0x0000000000090002L});
    public static final BitSet FOLLOW_ruleSensor_in_ruleSystem243 = new BitSet(new long[]{0x0000000000080002L});
    public static final BitSet FOLLOW_rulePackage_in_entryRulePackage280 = new BitSet(new long[]{0x0000000000000000L});
    public static final BitSet FOLLOW_EOF_in_entryRulePackage290 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_14_in_rulePackage327 = new BitSet(new long[]{0x0000000000000020L});
    public static final BitSet FOLLOW_RULE_STRING_in_rulePackage344 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_ruleProperties_in_entryRuleProperties385 = new BitSet(new long[]{0x0000000000000000L});
    public static final BitSet FOLLOW_EOF_in_entryRuleProperties395 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_15_in_ruleProperties432 = new BitSet(new long[]{0x0000000000000020L});
    public static final BitSet FOLLOW_RULE_STRING_in_ruleProperties449 = new BitSet(new long[]{0x0000000000002000L});
    public static final BitSet FOLLOW_13_in_ruleProperties466 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_ruleElettrodomestico_in_entryRuleElettrodomestico502 = new BitSet(new long[]{0x0000000000000000L});
    public static final BitSet FOLLOW_EOF_in_entryRuleElettrodomestico512 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_16_in_ruleElettrodomestico549 = new BitSet(new long[]{0x0000000000000010L});
    public static final BitSet FOLLOW_RULE_ID_in_ruleElettrodomestico566 = new BitSet(new long[]{0x0000000000020000L});
    public static final BitSet FOLLOW_17_in_ruleElettrodomestico583 = new BitSet(new long[]{0x0000000003800000L});
    public static final BitSet FOLLOW_ruleConsumption_in_ruleElettrodomestico604 = new BitSet(new long[]{0x0000000000040000L});
    public static final BitSet FOLLOW_18_in_ruleElettrodomestico616 = new BitSet(new long[]{0x000000000C000000L});
    public static final BitSet FOLLOW_ruleUsage_in_ruleElettrodomestico637 = new BitSet(new long[]{0x0000000000002000L});
    public static final BitSet FOLLOW_13_in_ruleElettrodomestico649 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_ruleSensor_in_entryRuleSensor685 = new BitSet(new long[]{0x0000000000000000L});
    public static final BitSet FOLLOW_EOF_in_entryRuleSensor695 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_19_in_ruleSensor732 = new BitSet(new long[]{0x0000000000100000L});
    public static final BitSet FOLLOW_20_in_ruleSensor744 = new BitSet(new long[]{0x0000000000000010L});
    public static final BitSet FOLLOW_RULE_ID_in_ruleSensor764 = new BitSet(new long[]{0x0000000000202000L});
    public static final BitSet FOLLOW_21_in_ruleSensor777 = new BitSet(new long[]{0x0000000000000040L});
    public static final BitSet FOLLOW_RULE_DOUBLE_in_ruleSensor794 = new BitSet(new long[]{0x0000000000400000L});
    public static final BitSet FOLLOW_22_in_ruleSensor811 = new BitSet(new long[]{0x0000000000000040L});
    public static final BitSet FOLLOW_RULE_DOUBLE_in_ruleSensor828 = new BitSet(new long[]{0x0000000000002000L});
    public static final BitSet FOLLOW_13_in_ruleSensor847 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_23_in_ruleConsumption897 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_24_in_ruleConsumption914 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_25_in_ruleConsumption931 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_26_in_ruleUsage976 = new BitSet(new long[]{0x0000000000000002L});
    public static final BitSet FOLLOW_27_in_ruleUsage993 = new BitSet(new long[]{0x0000000000000002L});

}